from django.urls import path,re_path
from . import views

urlpatterns = [
    # re_path('^product/$',views.InsertView.as_view()), #// 轮播数据
    re_path('^weixin/wxLogin/(?P<code>\d+)/$', views.LoginSView.as_view()),

    re_path('^smscode$',views.SMScodeView.as_view()),
    re_path('^weixin/getuserInfo/(?P<code>\d+)/$', views.UserInfoView.as_view()),
    re_path('^cart/getCartList$', views.GetCartList.as_view()),
    re_path('^cart/addToCart/(?P<goodsId>\d+)/(?P<count>[-+]?\d+)$', views.AddToCart.as_view()),
    re_path('^cart/checkCart/(?P<goodsId>\d+)/(?P<isChecked>[-+]?\d+)/$', views.CheckCart.as_view()),
    re_path('^cart/delete/(?P<goodsId>\d+)/$', views.DeleteCart.as_view()),

    re_path('^userAddress/findUserAddress$', views.FindAddress.as_view()),
    re_path('^userAddress/delete/(?P<id>\d+)$', views.DeleteAddress.as_view()),
    re_path('^userAddress/save$', views.AddAddress.as_view()),
    re_path('^userAddress/update$', views.UpdateAddress.as_view()),
    re_path('^userAddress/(?P<id>\d+)$', views.InfoAddress.as_view()),

    re_path('^userAddress/getOrderAddress$', views.GetOrderAddress.as_view()),
    re_path('^order/trade$', views.GetTrade.as_view()),

    re_path('^fileUpload$', views.FileUp.as_view()),
]